import request from '@/utils/request'

const {
  get: $get,
  post: $post,
  delete: $delete,
  download: $download,
  post_query: $post_query
} = request


// 办理任务
export const completeTask = data =>{
  return $post_query('/activiti/activiti/process/complete', data)
}

// 转派任务
export const delegateTask = data =>{
  return $post_query('/activiti/activiti/process/delegate', data)
}

// 撤销流程实例
export const cancelApply = data =>{
  return $post_query('/activiti/activiti/process/cancelApply', data)
}

// 挂起激活流程实例
export const suspendOrActiveApply = data =>{
  return $post_query('/activiti/activiti/process/suspendOrActiveApply', data)
}

// 驳回或跳转到指定节点
export const jumpAppointProcess = (taskId, sid) =>{
  return $get('/activiti/activiti/process/jump/'+taskId+"/"+sid)
}
